#include <pybind11/pybind11.h>
#include <pybind11/stl.h>
#include <Display/Renders/render.h>
#include <string>
using namespace PhysLeo;
namespace py = pybind11;

template<typename T>
void declareRender(py::module &mod, const std::string& typestr)
{
    using class_type = Render<T>;
    auto pyclass_name = std::string("Render") + typestr;
    py::class_<class_type, std::shared_ptr<class_type>>cls(mod, pyclass_name.c_str());

    cls.def("isHidden", &class_type::isHidden);
    cls.def("hide", &class_type::hide);
    cls.def("show", &class_type::show);
}

void initRender(py::module &mod)
{
    declareRender<float>(mod, std::string("F"));
    declareRender<double>(mod, std::string("D"));
}